<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "set_rss_sitemap_crawler".
 *
 * @property int $id
 * @property string $url 采集路径
 * @property int $day 最近几天的数据
 * @property int $max_pages_crawl 单次采集最大抓取页面数
 * @property string|null $status 状态
 * @property string|null $last_at 最后一次抓取时间
 */
class SetRssSitemapCrawler extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 'set_rss_sitemap_crawler';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['url'], 'required'],
            [['day', 'max_pages_crawl'], 'integer'],
            [['status'], 'string'],
            [['last_at'], 'safe'],
            [['url'], 'string', 'max' => 500],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'url' => 'Url',
            'day' => 'Day',
            'max_pages_crawl' => 'Max Pages Crawl',
            'status' => 'Status',
            'last_at' => 'Last At',
        ];
    }
}
